Tree Map

Treemap - Savings by Hic3 Drug Classification

hic3_tree <- hic3 %>% select(total_value, drug, hic3_description) %>% group_by(hic3_description, drug, total_value)

treemapclass <- hic3_tree %>% treemap(dtf = hic3_tree,
                                       index = c("hic3_description", "drug"),
                                       vSize = "total_value")


Commentary


I’m having some issues with the tree map covering up other parts of my flex dashboard.

Though it isn’t a deal-breaking issue, it would be nice if I could see the code above.

Those are just my two-cents.

Savings Scatterplot

Savings by Month

comb_vizzz <- nov_dec_sav %>% ggplot(aes(x=savings_po_date, y=total_value, label=drug))+ geom_jitter(stat="Identity", aes(fill=savings_po_date, size=total_value, alpha=total_value)) + ggtitle("Monthly Savings", "The official subtitle")

ggplotly(comb_vizzz)

Savings by Drug Class

hic3viz <- hic3 %>% ggplot(aes(x=hic3_description, y=total_value, label=hic3_description)) + geom_jitter(stat="Identity", aes(fill=hic3_description, size=total_value, alpha=total_value)) + ggtitle("Monthly Savings by Class", "The official subtitle") + theme(legend.position = "none") + theme(axis.text.x=element_text(angle = 270, hjust = 1, size = 4))

ggplotly(hic3viz)